#include<bits/stdc++.h>

#define rp(i,a,b) for(int i=a;i<b;++i)
#define rrp(i,b,a) for(int i=b;i>=a;--i)

using namespace std;

int main(){
	int n;scanf("%d", &n);
	std::vector<string> v1,v2;
	string stmp;
	rp(i , 0 , n){
		cin>>stmp;
		if(stmp[0]=='!'){
			stmp=stmp.substr(1);
			v2.push_back(stmp);
		}else{
			v1.push_back(stmp);
		}
	}
	sort(v1.begin(),v1.end());
	sort(v2.begin(),v2.end());
	int i = 0, j = 0;
	while(i<v1.size()&&j<v2.size()){
		if(v1[i] == v2[j]){
			cout<<v1[i]<<endl;
			return 0;
		}else if(v1[i]<v2[j])++i;
		else ++j;
	}
	printf("satisfiable\n");
	return 0;
}